extract-category ket
extract the "category" from the given ket
categories are separated by ": "
with the most general category on the left, and the most specific on the right
for example |animal: mammal: dog>
has the most general category "animal", then the category "mammal" and then finally the "value" dog
categories can be considered a type for the object
Eg, |word: house> says house is a type of word
and |food: apple> says apple is a type of food
and we can define operators with respect to them
Eg, op |food: *> #=> ...
will define "op" with respect to all objects of type\category "food".